Skip to content

feat: PuLID-Flux identity-injection support#1595

Open
RapidMark wants to merge 1 commit into
leejet:masterfrom
CloudhandsAI:cloudhands/pulid-flux-gguf
Open

feat: PuLID-Flux identity-injection support#1595
RapidMark wants to merge 1 commit into
leejet:masterfrom
CloudhandsAI:cloudhands/pulid-flux-gguf

Conversation

@RapidMark
Copy link
Copy Markdown
Contributor

Adds PuLID-Flux identity injection to the Flux denoise path (works on CUDA / Vulkan / HIP).

This supersedes #1542 — I rebased onto current master and reworked the id-embedding into a gguf container like @Green-Sky suggested over there, so it loads through the same gguf_init_from_file path as the pulid_ca weights and the custom header is gone. Opening fresh rather than force-pushing #1542 because that branch had drifted onto an old master and the history got tangled; a clean rebase seemed easier to review.

What's in it:

  • src/pulid.hpp — the id-embedding module
  • id-embedding threaded through flux.hpp + stable-diffusion.cpp
  • --pulid / id-image flags in examples/common
  • scripts/pulid_extract_id.py — produces the embedding (writes the gguf)
  • docs/pulid.md — usage

The embedding is a single fp16 tensor in a gguf file. Tested end to end on NVIDIA (CUDA + Vulkan), AMD RDNA2 (Vulkan) and RDNA4 (ROCm + Vulkan) — same seed, identity holds across backends.

Adds PuLID-Flux identity injection to the Flux denoise path: a pulid.hpp
module, the id-embedding threaded through flux.hpp and stable-diffusion.cpp,
CLI flags in examples/common, and scripts/pulid_extract_id.py to produce
the embedding. The id-embedding is stored as a gguf container (a single
fp16 tensor) and loaded through the same gguf_init_from_file path as the
pulid_ca weights, so there's no bespoke binary header.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant